angular.module('app').controller('returnCtrl', 
['$scope', '$rootScope', 'stateV', 'http','$state',
function($scope, $rootScope,stateV,http,$state) 
{
	$rootScope.header = false;

	var url = window.location.href; //获取url中"?"符后的字串
	url = url.substr(url.indexOf("return?")+6);
	var theRequest = new Object();
	if (url.indexOf("?") != -1) {
		var str = url.substr(1);
	    strs = str.split("&");
	    for(var i = 0; i < strs.length; i ++) {
	   		theRequest[strs[i].split("=")[0]]=(strs[i].split("=")[1]);
	    }
	}

	http.get(globalConfig.web+"/order/detail?orderid="+theRequest.out_trade_no,  function(data, status){
		if(status==200){
			$scope.detail = data;
		}
	})

}]);